import React, { FC } from 'react';
import styles from './style.less';
import { Card, Col, Row } from 'antd';
import { Boss } from '@/models/boss';
import JoinForm from '@/pages/boss/center/BossInfo/JoinForm';

const BossInfo: FC<any> = ({ location, dispatch }) => {
  const { state }: { state: Boss } = location;

  return (
    <div>
      <Card className={styles.content}>
        <Row justify="start" type="flex">
          <Col span={24}>
            <div>
              <h2 className={styles.title}>{state.postion}</h2>
              <p className={styles.position}>
                {state.address +
                  ' | ' +
                  state.startYear +
                  '-' +
                  state.endYear +
                  '工作经验' +
                  ' | ' +
                  state.education}
              </p>
              <br />
              <br />
              <br />
              <p className={styles.mainTitle}>职位信息</p>
              <div className={styles.padContent}>
                <p>岗位职责：</p>
                <div dangerouslySetInnerHTML={{ __html: state.positionDuty }}></div>
                <br />
                <p>岗位要求：</p>
                <div dangerouslySetInnerHTML={{ __html: state.positionCommand }}></div>
              </div>
              <br />
              <br />
              <p className={styles.mainTitle}>联系我们</p>
              <div className={styles.padContent}>
                <p> {state.contect}</p>
              </div>
              <JoinForm boss={state} />
            </div>
          </Col>
        </Row>
      </Card>
    </div>
  );
};

export default BossInfo;
